From: Jasper St. Pierre Date: Mon, 4 Nov 2013 22:23:28 +0000 (-0500) Subject: viewSelector: Give the active page key focus when it is shown X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~3009 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=ec2bb039ae7ab3f3504bfe0fdba6c715f5a838fd;p=gnome-shell.git viewSelector: Give the active page key focus when it is shown Rather than implement special focus policies like only allowing keynav when pressing down, simply give the active page key focus when entering the overview. This may break stuff, as it's somewhat of a tricky patch to get right. Testing this one would be super appreciated. https://bugzilla.gnome.org/show_bug.cgi?id=644306 --- diff --git a/js/ui/viewSelector.js b/js/ui/viewSelector.js index 0bc0f20af..75ef3ad83 100644 --- a/js/ui/viewSelector.js +++ b/js/ui/viewSelector.js @@ -186,6 +186,7 @@ const ViewSelector = new Lang.Class({ params = Params.parse(params, { a11yFocus: null }); let page = new St.Bin({ child: actor, + visible: false, x_align: St.Align.START, y_align: St.Align.START, x_fill: true, @@ -210,7 +211,7 @@ const ViewSelector = new Lang.Class({ oldPage.hide(); this.emit('page-empty'); - + this._activePage.navigate_focus(null, Gtk.DirectionType.TAB_FORWARD, false); this._activePage.show(); Tweener.addTween(this._activePage, { opacity: 255, @@ -281,14 +282,6 @@ const ViewSelector = new Lang.Class({ return true; } else if (this._shouldTriggerSearch(symbol)) { this.startSearch(event); - } else if (!this._searchActive) { - if (symbol == Clutter.Tab || symbol == Clutter.Down) { - this._activePage.navigate_focus(null, Gtk.DirectionType.TAB_FORWARD, false); - return true; - } else if (symbol == Clutter.ISO_Left_Tab) { - this._activePage.navigate_focus(null, Gtk.DirectionType.TAB_BACKWARD, false); - return true; - } } return false; },